<html><head><meta charset="gb2312"/><title>Clipboard.pb</title></head>
<body bgcolor="#EFF1F0" link="#3A3966" vlink="#000000" alink="#000000">
<pre><font face="Courier New, Courier, mono"size="2"><font color="#3A3966">;
</font><font color="#3A3966">; ------------------------------------------------------------
</font><font color="#3A3966">;
</font><font color="#3A3966">;   PureBasic - Clipboard example file
</font><font color="#3A3966">;
</font><font color="#3A3966">;    (c) Fantaisie Software
</font><font color="#3A3966">;
</font><font color="#3A3966">; ------------------------------------------------------------
</font><font color="#3A3966">;
</font>
<font color="#3A3966">; Paste text to the clipboard..
</font><font color="#3A3966">SetClipboardText</font>("PureBasic pasted text example.")

<font color="#3A3966">; Display the contents of the clipboard...
</font><font color="#3A3966">MessageRequester</font>("Info", "Text in the clipboard"+<font color="#FF0000">#LF$</font>+"'"+<font color="#3A3966">GetClipboardText</font>()+"'", 0)

<font color="#3A3966">; Now paste an image...
</font>
<b><font color="#3A3966">If</font></b> <font color="#3A3966">LoadImage</font>(0,<font color="#3A3966"> OpenFileRequester</font>("Load a picture","","Bitmap (*.bmp)|*.bmp",0))
  <b><font color="#3A3966">If</font></b> <font color="#3A3966">SetClipboardImage</font>(0)

<font color="#3A3966">    MessageRequester</font>("Info", "Image correctly pasted to the clipboard."+<font color="#3A3966">Chr</font>(10)+"Open 'Paint' to test it !", 0)
  <b><font color="#3A3966">EndIf</font></b>
<b><font color="#3A3966">EndIf</font></b></font></pre>
</body></html>
